<?php
class Controller_App_Prize extends Controller_App_Template
{
    public function __construct ($req, $res)
    {
        $this->template = "smarty:app/service/blank";
        parent::__construct($req, $res);
    }

    public function action_index ()
    {
        $this->action_list();
    }

    /**
     * 展示正在执行及未执行完的福利列表
     */
    public function action_list()
    {
        $uid = $this->_uid;
        $list = App_Prize::get_list($uid);
//        var_dump($list);exit;
        $this->template->set('list', $list);
        $this->template->set_filename("smarty:app/test/prizelist");
    }
    
    /**
     * 获取已经获得的福利列表
     */
    public function action_finish_prize()
    {
        $uid = $this->_uid;
        $list = App_Prize::get_finish_list($uid);
        $this->template->set('list', $list);
        $this->template->set_filename("smarty:app/test/prizefinishlist");
    }

}
